//
//  YZSportTracking.h
//  runrun
//
//  Created by yongzhen on 16/10/21.
//  Copyright © 2016年 yongzhen. All rights reserved.
//
// 运动轨迹追踪
#import <UIKit/UIKit.h>
#import "YZSportTrackingLine.h"

typedef enum: NSUInteger{
    YZSportTypeRun,
    YZSportTypeWalk,
    YZSportTypeRide,
    
}YZSportType;

typedef enum: NSUInteger{
    YZSportStatusContinue = 0,
    YZSportStatusPause,
    YZSportStatusOver,
    
}YZSportStatus;

typedef enum: NSUInteger{
    YZSportGPSStatusDisconnect = 0,
    YZSportGPSStatusBad,
    YZSportGPSStatusNormal,
    YZSportGPSStatusGood,
    
}YZSportGPSStatus;

@interface YZSportTracking : NSObject
-(instancetype)initWithType:(YZSportType)type sportStatus:(YZSportStatus)sportstatus;



@property (nonatomic,assign,readonly)YZSportType sportType;
@property (nonatomic,assign)YZSportStatus sportStatus;
@property (nonatomic,assign)YZSportGPSStatus gpsSinal;
@property (nonatomic,strong,readonly)UIImage * sportImage;
-(MAPolyline *)appendLocation:(CLLocation *)location;
@property (nonatomic,readonly)double avgSpeed;
@property (nonatomic,readonly)double maxSpeed;
@property (nonatomic,readonly)double totalTime;
@property (nonatomic,readonly)double totalDistance;
@property (nonatomic,readonly)CLLocation * sportStartLocation;
/**
 总时长 00:00:00 格式的字符串
 */
@property (nonatomic, readonly) NSString *totalTimeStr;



@end
